home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Controls / Visual Basic Controls.iso / vbcontrol / ahmsyscm / _setup.1 / AHMTFormSaver.hpp < prev    next >
Encoding:
C/C++ Source or Header  |  1998-11-12  |  3.4 KB  |  92 lines

  1. // Borland C++ Builder
  2. // Copyright (c) 1995, 1998 by Borland International
  3. // All rights reserved
  4.  
  5. // (DO NOT EDIT: machine generated header) 'AHMTFormSaver.pas' rev: 3.00
  6.  
  7. #ifndef AHMTFormSaverHPP
  8. #define AHMTFormSaverHPP
  9. #include <AHMTFormHook.hpp>
  10. #include <AHMSystem.hpp>
  11. #include <AHMTStoreData.hpp>
  12. #include <Controls.hpp>
  13. #include <Forms.hpp>
  14. #include <Classes.hpp>
  15. #include <SysUtils.hpp>
  16. #include <Messages.hpp>
  17. #include <Windows.hpp>
  18. #include <SysInit.hpp>
  19. #include <System.hpp>
  20.  
  21. //-- user supplied -----------------------------------------------------------
  22.  
  23. namespace Ahmtformsaver
  24. {
  25. //-- type declarations -------------------------------------------------------
  26. typedef void __fastcall (__closure *TAHMOnStoreControl)(System::TObject* Sender, bool &Result);
  27.  
  28. class DELPHICLASS TAHMFormSaver;
  29. class PASCALIMPLEMENTATION TAHMFormSaver : public Ahmtformhook::TAHMHookComponent 
  30. {
  31.     typedef Ahmtformhook::TAHMHookComponent inherited;
  32.     
  33. private:
  34.     Ahmtstoredata::TAHMDataStore* FFormStore;
  35.     bool FLocal;
  36.     bool FStoreSize;
  37.     bool FStoreLocation;
  38.     bool FStoreState;
  39.     bool FStoreVisible;
  40.     bool FStoreControls;
  41.     Forms::TForm* FMyForm;
  42.     int intRestoreLeft;
  43.     int intRestoreTop;
  44.     int intRestoreWidth;
  45.     int intRestoreHeight;
  46.     bool bolWindowStateSet;
  47.     Classes::TNotifyEvent FOnShow;
  48.     Forms::TCloseEvent FOnClose;
  49.     Classes::TNotifyEvent FOnStore;
  50.     TAHMOnStoreControl FOnStoreControl;
  51.     Classes::TNotifyEvent FOnRestore;
  52.     void __fastcall StoreControl(Controls::TControl* TheControl);
  53.     void __fastcall RestoreControl(Controls::TControl* TheControl);
  54.     void __fastcall StoreWindow(Forms::TForm* TheForm);
  55.     void __fastcall RestoreWindow(Forms::TForm* TheForm);
  56.     void __fastcall MyStore(System::TObject* Sender, Forms::TCloseAction &Action);
  57.     void __fastcall MyRestore(System::TObject* Sender);
  58.     
  59. protected:
  60.     void __fastcall BeforeMaximize(void);
  61.     
  62. public:
  63.     __fastcall virtual TAHMFormSaver(Classes::TComponent* AOwner);
  64.     __fastcall virtual ~TAHMFormSaver(void);
  65.     virtual void __fastcall Hooked(Messages::TMessage &AMsg);
  66.     void __fastcall Store(void);
  67.     void __fastcall Restore(void);
  68.     int __fastcall ReadInt(System::AnsiString Section, int Error);
  69.     System::AnsiString __fastcall ReadStr(System::AnsiString Section, System::AnsiString Error);
  70.     bool __fastcall ReadBool(System::AnsiString Section, bool Error);
  71.     
  72. __published:
  73.     __property Ahmtstoredata::TAHMDataStore* FormStore = {read=FFormStore, write=FFormStore};
  74.     __property bool StoreSize = {read=FStoreSize, write=FStoreSize, default=1};
  75.     __property bool StoreLocation = {read=FStoreLocation, write=FStoreLocation, default=1};
  76.     __property bool StoreState = {read=FStoreState, write=FStoreState, default=1};
  77.     __property bool StoreVisible = {read=FStoreVisible, write=FStoreVisible, default=1};
  78.     __property bool StoreControls = {read=FStoreControls, write=FStoreControls, nodefault};
  79.     __property Classes::TNotifyEvent OnStore = {read=FOnStore, write=FOnStore};
  80.     __property TAHMOnStoreControl OnStoreControl = {read=FOnStoreControl, write=FOnStoreControl};
  81.     __property Classes::TNotifyEvent OnRestore = {read=FOnRestore, write=FOnRestore};
  82. };
  83.  
  84. //-- var, const, procedure ---------------------------------------------------
  85.  
  86. }    /* namespace Ahmtformsaver */
  87. #if !defined(NO_IMPLICIT_NAMESPACE_USE)
  88. using namespace Ahmtformsaver;
  89. #endif
  90. //-- end unit ----------------------------------------------------------------
  91. #endif    // AHMTFormSaver
  92.